package cn.hxzy.controller;


import cn.hxzy.domain.Choose;
import cn.hxzy.response.R;
import org.apache.ibatis.annotations.Delete;
import org.springframework.web.bind.annotation.*;

import java.util.ArrayList;
import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author niuyi
 * @since 2024-06-22
 */
@RestController
@RequestMapping("/choose")
public class ChooseController {


    //新增选项
    @PostMapping("/insert")
    public R insert1(@RequestBody Choose choose) {
        return R.success("新增成功");
    }

    //删除选项
    @DeleteMapping("/delete")
    public R delete(@RequestParam Integer chooseId) {
        return R.success("删除成功");
    }

    //修改选项内容
    @PatchMapping("/change")
    public R change1(@RequestParam String chooseText, @RequestParam Integer chooseId) {
        return R.success("修改成功");
    }

    //查看选项内容

    /**
     *
     * @param exercisesId 习题编号
     * @return
     */
    @GetMapping("/select")
    public R select(@RequestParam Integer exercisesId){
        return R.success(new ArrayList<Choose>());
    }


}

